package com.xuyang.data;

import java.io.IOException;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

/**
 * Servlet implementation class CallWaiter
 */
public class CallWaiter extends HttpServlet {
	private static final long serialVersionUID = 1L;
	protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
		int seatNumber=Integer.parseInt(request.getParameter("seatNumber"));
		String value=request.getParameter("value");
		System.out.println(seatNumber+"号客人发来消息:");
		System.out.println(value);
		response.getWriter().write("OK");
	}
	protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
		request.setCharacterEncoding("UTF-8");
		doGet(request, response);
	}

}
